
package es.esp.ut08.herencia;
/**
 *
 * @author Francisco Peguero
 */
public class Zoo {

    public static void main(String[] args) {
        
        Animal a = new Dog();        
        a.getHunger();
        a.makeNoise();
        a.isAwake();
        a.eat();
        a.getHunger();
        System.out.println(a instanceof Dog);
        System.out.println(a instanceof Canine);
        System.out.println(a instanceof Animal);
        System.out.println(a instanceof Object);
        
        //Interfaces
        System.out.println("---Interfaces---");
        Lion l = new Lion();
        l.stand();
        Trainable beast = new Lion();
        beast.sit();
        beast.stand();
        beast = new Dog();
        beast.sit();
        beast.stand();
        
        //Inheritance with Concrete Classes
        System.out.println("---Inheritance with Concrete Classes---");
        SeeingEyeDog d = new SeeingEyeDog(5);
        d.getTrackingCode();
        System.out.println(d instanceof SeeingEyeDog);
        System.out.println(d instanceof Dog);
        System.out.println(d instanceof Canine);
        System.out.println(d instanceof Animal);
        System.out.println(d instanceof Object);
        
    }
}
